package com.android.qjpmc.application_module.viewModel;

import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.android.qjpmc.application_module.contract.ReportDataFragmentContract;
import com.android.qjpmc.application_module.contract.StationVideoFragmentContract;
import com.android.qjpmc.application_module.model.ReportDataFragmentModel;
import com.android.qjpmc.application_module.model.StationVideoFragmentModel;
import com.android.qjpmc.bean.GroupPointHisListBean;
import com.android.qjpmc.bean.PointParameterBean;
import com.android.qjpmc.bean.PointTimeDataBean;
import com.android.qjpmc.bean.StationDataBean;
import com.android.qjpmc.bean.StationVideoListBean;
import com.android.qjpmc.widget.mvvm.factory.CreateModel;
import com.android.qjpmc.widget.retrofithelper.rxsubscriber.ProgressObserver;
import com.android.qjpmc.widget.utils.ToastUtils;
import com.orhanobut.logger.Logger;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.functions.Function;
import io.reactivex.schedulers.Schedulers;

@CreateModel(StationVideoFragmentModel.class)
public class StationVideoFragmentViewModel extends StationVideoFragmentContract.ViewModel {

    public void getVideoListOfStation(StationDataBean stationData, String stationId) {


        mModel.getVideoListOfStation(stationId)
                .subscribe(new ProgressObserver<List<StationVideoListBean>>(false, this) {
                    @Override
                    public void _onNext(List<StationVideoListBean> videoListBeanList) {
                        mView.returnVideoList(videoListBeanList);
                    }
                });


    }
}
